project(
  log
  LANGUAGES CXX
)

set(CMAKE_CXX_STANDARD 17)
find_package(Qt5 COMPONENTS Widgets Core REQUIRED)

add_definitions(-DQLS_LOG_LIBRARY)

set(_srcs
    src/qls_log.cpp
)

set(_headers
    include/log/qls_log.h
    include/log/qls_log_global.h
)

add_library(log SHARED ${_srcs} ${_headers})
target_link_libraries(log PUBLIC
    QsLog
    Qt5::Widgets Qt5::Core ${CMAKE_THREAD_LIBS_INIT}
)
target_link_libraries(log PRIVATE settings)
target_include_directories(log PUBLIC include)

add_subdirectory(QsLog)
